Repository navigation
Conversation
5 of 9 tasks
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Operator image on Red Hat Hummingbird (spike)
Part of stackabletech/issues#921
Adds
hummingbird-spike/Dockerfile, an alternative todocker/Dockerfilethat builds the operator on Red Hat Hummingbird with no UBI stage.It follows the approach of the ZooKeeper product image spike (stackabletech/docker-images#1757).
docker/Dockerfileis generated from operator-templating, so it is not touched.How it works
These are the stages in the Dockerfile:
registry.access.redhat.com/hi/rust:latest-builder. It ships cargo and rustc, and it has dnf (the plainhi/rustimage does not).gccis needed as the linker and for theringandlibgit2build scripts. The image already ships it (gcc-16.2.1), so the Dockerfile does not install it. The operator is built withcargo auditable build --locked --release./additions, with ownership for UID782252253and group0(g=u). It prints thelddoutput of the binary.FROM registry.access.redhat.com/hi/core-runtime(RUNTIME_BASE), only adds/additionsand the same labels,ENTRYPOINTandCMD ["run"]asdocker/Dockerfile.No user is created. The image runs as the numeric UID without a passwd entry, which works in Kubernetes and OpenShift and avoids editing
/etc/passwd, which belongs to an RPM of the base image.docker-build-humm.The image is tagged
<registry>/<project>/zookeeper-operator:<version>-<ARCH>-humm.OpenShift
✅ Preflight
✅ Operator Certification Pipeline
The certification pipeline was run from the branch stackable-zookeeper-0.0.0-dev-humm
Differences from the UBI image
The runtime is whatever
hi/core-runtimeships, plus the operator. Not in the image:nano,iputils(not in the Hummingbird repo, as in the ZooKeeper spike).libkadm5andkrb5-libs. In the source, Kerberos only appears as anAuthenticationClassProvidervariant of the CRD. Whether the binary links Kerberos libraries is checked with thelddoutput of the build (see below).ca-certificates(unlesscore-runtimehas them). No shell means nokubectl cp(it needstar) and no debugging inside the container.stackableuser and group.The Rust toolchain comes from the image's
rustpackage, not fromrust-toolchain.toml.The build prints both versions, but does not fail on a mismatch. Currently the image has rustc 1.100.0 and the repo pins 1.99.0.
Security audit
Hummingbird based image:

UBI9 based image:

Status
make docker-build-humm.rust-toolchain.toml(1.99.0). It does not:hi/rust:latest-builderhas 1.100.0.FROM scratchversion, retest withcore-runtime).lddin theadditionsstage are all provided bycore-runtime(this covers Kerberos).ca-certificatesfrom the image.builtcrate records the commit hash (it needs a.gitdirectory in the build context, which a git worktree does not have).core-runtime).preflight check containerpasses (amd64, 11 of 11 checks).FROM scratchimage. Thecore-runtimeimage has not been through the pipeline (DeployableByOLM).